<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<link href="../css/docs.css" type="text/css" rel="stylesheet" />
<link href="../css/prettify.css" type="text/css" rel="stylesheet" />
<script src="../js/prettify.js" type="text/javascript"></script>
</head>
<body onLoad="prettyPrint()">
<div class="g-unit" id="doc-content">
<div id="api-info-block">
<div class="api-level">H3C CAS云管理平台</div>
</div>
<div id="jd-header">
<h1>删除虚拟机网卡连接</h1>
</div>
<div id="jd-content">
<div class="jd-descr">
<p>
	删除虚拟机网卡连接
</p>
<h2><a name="uri"></a>接口 URI</h2>
<p>/cas/casrs/vm/vnic/conn</p>
<h2><a name="access"></a>访问方法</h2>
<dl>
  <dt><b>HTTP 方法</b></dt>
  <dd>PUT</dd>
  <dt><b>消息体</b></dt>
  <div class="source">
  	<pre class="prettyprint lang-xml">&lt;vnic&gt;<br>  &lt;vmId&gt;20&lt;/vmId&gt;<br>  &lt;hostId&gt;2&lt;/hostId&gt;<br>  &lt;vmName&gt;vmTest&lt;/vmName&gt;<br>  &lt;mac&gt;20:30:40:50:60:70&lt;/mac&gt;
  &lt;type&gt;0&lt;/type&gt;<br>&lt;/vnic&gt;</pre>
  </div>
</dl>
<dt><a name="detail"></a><b>元素含义</b></dt>
<table class="jd-sumtable" id="pubmethods">
  <tbody>
    <tr>
      <th colspan="2"><span class="prettyprint lang-xml">vSwitch</span>各子元素</th>
	<tr>
      <td class="jd-typecol"><span class="prettyprint lang-xml">vmId</span></td>
      <td class="jd-linkcol" width="100%"><span class="sympad">虚拟机ID</span>
          <div class="jd-descrdiv">长整型（long）类型。</div></td>
    </tr>
    <tr class="alt-color">
      <td class="jd-typecol"><span class="prettyprint lang-xml">hostId</span></td>
      <td class="jd-linkcol" width="100%"><span class="sympad">虚拟机的宿主主机ID。</span>
          <div class="jd-descrdiv">长整型（long）类型。</div></td>
    </tr>
	<tr>
      <td class="jd-typecol"><span class="prettyprint lang-xml">vmName</span></td>
      <td class="jd-linkcol" width="100%"><span class="sympad">虚拟机名称。</span>
          <div class="jd-descrdiv">字符串（String）类型。</div></td>
    </tr>
	<tr class="alt-color">
      <td class="jd-typecol"><span class="prettyprint lang-xml">mac</span></td>
      <td class="jd-linkcol" width="100%"><span class="sympad">将要修改的虚拟机网卡MAC地址。</span>
          <div class="jd-descrdiv">字符串（String）类型。</div></td>
    </tr>
	<tr>
      <td class="jd-typecol"><span class="prettyprint lang-xml">type</span></td>
      <td class="jd-linkcol" width="100%"><span class="sympad">操作类型：1修改；0：删除</span>
          <div class="jd-descrdiv">整数（int）类型。</div></td>
    </tr>
</table>

<h2><a name="result"></a>返回结果</h2>
<dl>
  <dt><b>状态码</b></dt>
  <dd>
  <ul>
    <li>204(No Content)：成功；409(Conflict)：失败</li>
  </ul>
  </dd>
  <dt><b>消息头</b></dt>
  <br>
  <pre class="prettyprint lang-xml">HTTP/1.1 204 No Content<br>Content-Type: application/xml</pre>
</dl>

<p>&nbsp;</p>
<h2><a name="example"></a>应用举例</h2>
    <p>1.修改虚拟机vmtest的网0c:da:41:1d:c6:11的连接。</p>
    <dl>
      <dt><b>请求</b></dt>
      <div class="source">
        <pre class="prettyprint lang-xml">PUT http://localhost:8080/cas/casrs/vm/vnic/conn
accept: application/xml
&lt;vnic&gt;<br>  &lt;vmId&gt;110&lt;/vmId&gt;<br>  &lt;hostId&gt;2&lt;/hostId&gt;<br>  &lt;vmName&gt;vmtest&lt;/vmName&gt;<br>  &lt;mac&gt;0c:da:41:1d:c6:11&lt;/mac&gt;  
  &lt;type&gt;0&lt;/type&gt;<br>&lt;/vnic&gt;</pre>
      </div>
      <dt><b>回应</b></dt>
      <div class="source"><pre class="prettyprint lang-xml">HTTP/1.1 204 No Content<br>Content-Type: application/xml
...<br>无消息体<br></pre>
      </div>
    </dl>
</div>
</div>
</div>
</body>
</html>